use super::hitls_pki_types::{HITLS_PKI_LibCtx, HITLS_PKCS12_PwdParam, HITLS_PKCS12_EncodeParam};
use crate::bsl::bsl_types::BSL_Buffer;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _HITLS_PKCS12 {
    _unused: [u8; 0],
}
pub type HITLS_PKCS12 = _HITLS_PKCS12;
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct _HITLS_PKCS12_Bag {
    _unused: [u8; 0],
}
pub type HITLS_PKCS12_Bag = _HITLS_PKCS12_Bag;
unsafe extern "C" {
    pub fn HITLS_PKCS12_New() -> *mut HITLS_PKCS12;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_ProviderNew(
        libCtx: *mut HITLS_PKI_LibCtx,
        attrName: *const ::std::os::raw::c_char,
    ) -> *mut HITLS_PKCS12;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_Free(p12: *mut HITLS_PKCS12);
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_BagNew(
        bagId: u32,
        bagType: u32,
        bagValue: *mut ::std::os::raw::c_void,
    ) -> *mut HITLS_PKCS12_Bag;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_BagFree(bag: *mut HITLS_PKCS12_Bag);
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_BagCtrl(
        bag: *mut HITLS_PKCS12_Bag,
        cmd: i32,
        val: *mut ::std::os::raw::c_void,
        valType: u32,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_Ctrl(
        p12: *mut HITLS_PKCS12,
        cmd: i32,
        val: *mut ::std::os::raw::c_void,
        valLen: u32,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_ParseBuff(
        format: i32,
        encode: *const BSL_Buffer,
        pwdParam: *const HITLS_PKCS12_PwdParam,
        p12: *mut *mut HITLS_PKCS12,
        needMacVerify: bool,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_ProviderParseBuff(
        libCtx: *mut HITLS_PKI_LibCtx,
        attrName: *const ::std::os::raw::c_char,
        format: *const ::std::os::raw::c_char,
        encode: *const BSL_Buffer,
        pwdParam: *const HITLS_PKCS12_PwdParam,
        p12: *mut *mut HITLS_PKCS12,
        needMacVerify: bool,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_ParseFile(
        format: i32,
        path: *const ::std::os::raw::c_char,
        pwdParam: *const HITLS_PKCS12_PwdParam,
        p12: *mut *mut HITLS_PKCS12,
        needMacVerify: bool,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_ProviderParseFile(
        libCtx: *mut HITLS_PKI_LibCtx,
        attrName: *const ::std::os::raw::c_char,
        format: *const ::std::os::raw::c_char,
        path: *const ::std::os::raw::c_char,
        pwdParam: *const HITLS_PKCS12_PwdParam,
        p12: *mut *mut HITLS_PKCS12,
        needMacVerify: bool,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_GenBuff(
        format: i32,
        p12: *mut HITLS_PKCS12,
        encodeParam: *const HITLS_PKCS12_EncodeParam,
        isNeedMac: bool,
        encode: *mut BSL_Buffer,
    ) -> i32;
}
unsafe extern "C" {
    pub fn HITLS_PKCS12_GenFile(
        format: i32,
        p12: *mut HITLS_PKCS12,
        encodeParam: *const HITLS_PKCS12_EncodeParam,
        isNeedMac: bool,
        path: *const ::std::os::raw::c_char,
    ) -> i32;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct __locale_data {
    pub _address: u8,
}
